package com.beijing.cyou.params;

import com.beijing.cyou.model.UserOnline;
import com.beijing.cyou.model.UserVO;

public class UserParams {
	
	private Long userId ;

	private Long companyId;

	private Long parentId;

	private Long groupParentId;

	private Integer groupSequence;

	private Long orgzId;

	private Integer idLevel;
	
	public UserParams() {
		super();
	}

	public UserParams(Long userId) {
		this.userId = userId;
	}
	public UserParams(String token) {
		this.token = token;
	}
	public UserParams(Long userId, String token) {
		this.userId = userId;
		this.token = token;
	}

	public Long getUserId() {
		return userId;
	}
	public void setUserId(Long userId) {
		this.userId = userId;
	}

	public Long getCompanyId() {
		return companyId;
	}
	public void setCompanyId(Long companyId) {
		this.companyId = companyId;
	}

	public Long getParentId() {
		return parentId;
	}
	public void setParentId(Long parentId) {
		this.parentId = parentId;
	}

	public Long getGroupParentId() {
		return groupParentId;
	}
	public void setGroupParentId(Long groupParentId) {
		this.groupParentId = groupParentId;
	}

	public Integer getGroupSequence() {
		return groupSequence;
	}
	public void setGroupSequence(Integer groupSequence) {
		this.groupSequence = groupSequence;
	}

	public Long getOrgzId() {
		return orgzId;
	}
	public void setOrgzId(Long orgzId) {
		this.orgzId = orgzId;
	}

	
	public Integer getIdLevel() {
		return idLevel;
	}
	public void setIdLevel(Integer idLevel) {
		this.idLevel = idLevel;
	}

	private String duty;

	private String company;

	public void setParamsDefault() {
		this.duty = "普通职员";
		this.company = "畅游";
		this.companyId = 282L;
	}

	public String getDuty() {
		return duty;
	}
	public void setDuty(String duty) {
		this.duty = duty;
	}

	public String getCompany() {
		return company;
	}
	public void setCompany(String company) {
		this.company = company;
	}

	public UserParams(String userName, String userEmail, String domain, String usergender, String usercomment,
			String token) {
		this.token = token;
		this.domain = domain;
		this.userName = userName;
		this.userEmail = userEmail;
		this.usergender = usergender;
		this.usercomment = usercomment;
	}

	private String token;

	private String userName;

	private String userEmail;

	private String domain;

	private String usergender;

	private String usercomment;

	public String getToken() {
		return token;
	}
	public void setToken(String token) {
		this.token = token;
	}

	public String getUserName() {
		return userName;
	}
	public void setUserName(String userName) {
		this.userName = userName;
	}

	public String getUserEmail() {
		return userEmail;
	}
	public void setUserEmail(String userEmail) {
		this.userEmail = userEmail;
	}

	public String getDomain() {
		return domain;
	}
	public void setDomain(String domain) {
		this.domain = domain;
	}

	public String getUsergender() {
		return usergender;
	}
	public void setUsergender(String usergender) {
		this.usergender = usergender;
	}

	public String getUsercomment() {
		return usercomment;
	}
	public void setUsercomment(String usercomment) {
		this.usercomment = usercomment;
	}

	public UserVO changToUserVO() {
		UserVO user = new UserVO();
		user.setUserDomain(this.domain);
		user.setUserName(this.userName);
		user.setUserEmail(this.userEmail);
		user.setUserComment(this.usercomment);
		user.setUserGender(Integer.parseInt(usergender));
		return user;
	}

	public UserOnline changToUserOnline() {
		UserOnline user = new UserOnline();
		user.setDomain("cyou-inc.com");
		user.setLoginIp("http://know.cyou-inc.com/");
		user.setInner(false);
		user.setToken(this.token);
		user.setUserId(this.userId);
		user.setName(this.usercomment);
		user.setUserName(this.userName);
		return user ;
	}

	private boolean gender ;
	
	private String phone ;
	
	private String mobile ;
	
	private String address ;

	public boolean isGender() {
		return gender;
	}
	public void setGender(boolean gender) {
		this.gender = gender;
	}

	public String getPhone() {
		return phone;
	}
	public void setPhone(String phone) {
		this.phone = phone;
	}

	public String getMobile() {
		return mobile;
	}
	public void setMobile(String mobile) {
		this.mobile = mobile;
	}

	public String getAddress() {
		return address;
	}
	public void setAddress(String address) {
		this.address = address;
	}
	
	
	
}
